function t_initZoom(){var o=$isMobile?"":"showed";$('[data-zoomable="yes"]').length&&(window.tzoominited=!0,$('[data-zoomable="yes"]:not(.t-slds__thumbs_gallery)').addClass("t-zoomable"),$("body").append('
'),t_showZoom(),$(".t-zoomer__close, .t-zoomer__bg").click(function(){t_zoom_unscale(),$(".t-zoomer__scale").unbind(),$("body").removeClass("t-zoomer__show"),$("body").removeClass("t-zoomer__show_fixed"),$(".t-zoomer__wrapper .t-zoomer__scale").css("display","none"),$(document).unbind("keydown"),0!=$(document).find(".t-popup_show").length&&$(document).keydown(function(o){27==o.keyCode&&($(".t-zoomer__wrapper .t-zoomer__scale").css("display","none"),t_store_closePopup(!1))})}))}function t_showZoom(){$(".t-records").on("click",".t-zoomable",t_zoomHandler),$(".t-records").on("click",".t-slds__thumbs_gallery",t_zoomHandler)}function t_zoomHandler(){$(document).unbind("keydown"),$("body").addClass("t-zoomer__show"),$(".t-zoomer__container").html('');var o=$(this).closest(".r").attr("id"),e=$("#"+o).find(".t-zoomable:not(.t-slds__thumbs_gallery)");$("#"+o).find(".t-slds").length&&(e=$(this).closest(".t-slds").find(".t-zoomable:not(.t-slds__thumbs_gallery)"));e.each(function(){var o,e,t,s,_=$(this).attr("data-img-zoom-url").split(",");$(this).is("img")&&(o=$(this).attr("title"),e=$(this).attr("data-img-zoom-descr")),$(this).is("div")&&(o=$(this).attr("title"),e=$(this).attr("data-img-zoom-descr")),t=void 0!==o&&!1!==o?'
'+o+"
":"",s=void 0!==e&&!1!==e?'
'+e+"
":"",$(".t-carousel__zoomer__inner").append('")}),$(".t-carousel__zoomer__item").each(function(){$(this).css("display","block");var o=$(this).find(".t-zoomer__comments"),e=o.find(".t-zoomer__title"),t=o.find(".t-zoomer__descr");e.length||t.length||o.css("padding","0");var s=o.innerHeight();$(this).css("display",""),$(this).find(".t-carousel__zoomer__wrapper").css("bottom",s)});var t=$(this).attr("data-img-zoom-url"),s=$('.t-carousel__zoomer__img[src="'+t+'"]'),_=$(".t-carousel__zoomer__item");s.closest(_).show(0).addClass("active"),_.each(function(){$(this).attr("data-zoomer-slide-number",$(this).index())});var i,r=parseFloat($(".t-carousel__zoomer__item:visible").attr("data-zoomer-slide-number"));$(".t-carousel__zoomer__control_right").click(function(){t_zoom_unscale(),$(".t-zoomer__scale").unbind(),$(".t-zoomer__wrapper .t-zoomer__scale").css("display","none"),r=(r+1)%_.length,_.hide(0).removeClass("active").eq(r).show(0).addClass("active"),t_zoom_checkForScale()}),$(".t-carousel__zoomer__control_left").click(function(){t_zoom_unscale(),$(".t-zoomer__scale").unbind(),$(".t-zoomer__wrapper .t-zoomer__scale").css("display","none"),r=(r-1)%_.length,_.hide(0).removeClass("active").eq(r).show(0).addClass("active"),t_zoom_checkForScale()}),$(document).keydown(function(o){37==o.keyCode&&(t_zoom_unscale(),$(".t-zoomer__scale").unbind(),$(".t-zoomer__wrapper .t-zoomer__scale").css("display","none"),r=(r-1)%_.length,_.hide(0).removeClass("active").eq(r).show(0).addClass("active"),t_zoom_checkForScale()),39==o.keyCode&&(t_zoom_unscale(),$(".t-zoomer__scale").unbind(),$(".t-zoomer__wrapper .t-zoomer__scale").css("display","none"),r=(r+1)%_.length,_.hide(0).removeClass("active").eq(r).show(0).addClass("active"),t_zoom_checkForScale()),27==o.keyCode&&($("body").removeClass("t-zoomer__show"),$("body").removeClass("t-zoomer__show_fixed"),$(".t-zoomer__scale").unbind(),t_zoom_unscale(),$(".t-zoomer__wrapper .t-zoomer__scale").css("display","none"),$(document).unbind("keydown"),0!=$(document).find(".t-popup_show").length&&$(document).keydown(function(o){27==o.keyCode&&($(".t-zoomer__wrapper .t-zoomer__scale").css("display","none"),t_store_closePopup(!1))}))}),$(".t-carousel__zoomer__inner").bind("touchstart",function(o){i=o.originalEvent.touches[0].clientX}),$(".t-carousel__zoomer__inner").bind("touchend",function(o){var e=o.originalEvent.changedTouches[0].clientX;e+50